Java Magazine: Reactive Programming by Andrew Benstock
Author:Andrew Benstock [Benstock, Andrew]
Language: eng
Format: azw3
Publisher: UNKNOWN
Published: 2018-12-02T16:00:00+00:00
Reactive Spring
Proceeding from fundamentals, use the Spring Framework to quickly build a reactive application.
R
eactive programming is an approach to writing software that embraces asynchronous I/O. Asynchronous I/O is a small idea that portends big changes for software. The idea is simple: alleviate ineicient resource utilization by using resources that would otherwise sit idle as they waited for I/O activity. Asynchronous I/O inverts the normal design of I/O processing: clients are notiied of new data instead of asking for it. This approach frees the client to do other things while waiting for new notiications.
There is, of course, always the risk that too many notiications will overwhelm a client; so, a client must be able to push back, rejecting work it can’t handle. This is a fundamental aspect of low control in distributed systems. In reactive programming, the ability of the client to signal how much work it can manage is called back-pressure.
Many projects, such as Akka Streams, Vert.x, and RxJava, support reactive programming. [Vert.x and RxJava are examined in detail in the accompanying article, “Going Reactive with Eclipse Vert.x and RxJava,” on page 32. —Ed.] The Spring team has a project called Reactor, which provides reactive capabilities for the Spring Framework. There’s common ground across these diferent approaches, which has been summarized in the Reactive Streams initiative—an informal standard of sorts.
The Fundamental Data Types
The Reactive Streams initiative deines four data types.Publisher is a producer of values that might eventually arrive. A Publisher produces values of typeT, as shown in Listing 1.
Listing 1: The Reactive StreamsPublisher<T> package org.reactivestreams; public interface Publisher<T> {
void subscribe(Subscriber<? Super T> s);
}
Download
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.
What's Done in Darkness by Kayla Perrin(26614)
The Fifty Shades Trilogy & Grey by E L James(19094)
Shot Through the Heart: DI Grace Fisher 2 by Isabelle Grey(19078)
Shot Through the Heart by Mercy Celeste(18951)
Wolf & Parchment: New Theory Spice & Wolf, Vol. 10 by Isuna Hasekura and Jyuu Ayakura(17130)
Python GUI Applications using PyQt5 : The hands-on guide to build apps with Python by Verdugo Leire(17017)
Peren F. Statistics for Business and Economics...Essential Formulas 3ed 2025 by Unknown(16892)
Wolf & Parchment: New Theory Spice & Wolf, Vol. 03 by Isuna Hasekura and Jyuu Ayakura & Jyuu Ayakura(16839)
Wolf & Parchment: New Theory Spice & Wolf, Vol. 01 by Isuna Hasekura and Jyuu Ayakura & Jyuu Ayakura(16464)
The Subtle Art of Not Giving a F*ck by Mark Manson(14373)
The 3rd Cycle of the Betrayed Series Collection: Extremely Controversial Historical Thrillers (Betrayed Series Boxed set) by McCray Carolyn(14156)
Stepbrother Stories 2 - 21 Taboo Story Collection (Brother Sister Stepbrother Stepsister Taboo Pseudo Incest Family Virgin Creampie Pregnant Forced Pregnancy Breeding) by Roxi Harding(13668)
Scorched Earth by Nick Kyme(12783)
Drei Generationen auf dem Jakobsweg by Stein Pia(10978)
Suna by Ziefle Pia(10901)
Scythe by Neal Shusterman(10363)
The Ultimate Python Exercise Book: 700 Practical Exercises for Beginners with Quiz Questions by Copy(10180)
D:\Jan\FTP\HOL\Work\Alien Breed - Tower Assault CD32 Alien Breed II - The Horror Continues Manual 1.jpg by PDFCreator(10141)
De Souza H. Master the Age of Artificial Intelligences. The Basic Guide...2024 by Unknown(10133)
